<!DOCTYPE HTML>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="maximum-scale=1.0, minimum-scale=1.0, user-scalable=0, initial-scale=1.0, width=device-width"/>
    <meta name="format-detection" content="telephone=no, email=no, date=no, address=no">
    <title>WinA</title>
    <link rel="stylesheet" type="text/css" href="css/api.css"/>
    <link rel="stylesheet" type="text/css" href="css/box.css"/>
    <script type="text/javascript" src="script/public.js"></script>
    <style>
    	p{
    		color:#999;
    		padding:5px;
    	}



    </style>
    <script type="text/javascript">
		var mVideoTape = null;
		apiready = function(){
	    	mVideoTape = api.require('xinvideo');
	    }


        function openZhiBo(){
          var mData={
               indexName:'index_frm',
               fixed:true,
               videowidth:720,
               videoheight:1280,
               videofps:25,
               fixed:true,
               uri:'rtmp://push1.rocyblog.com:8935/test/',
               cameraorientation:90,
               outorientation:0,
               }
            mVideoTape.openLiveTelecast(mData)
        }


        function openRemoveZhiBo(){
            mVideoTape.removeLiveTelecast()
        }


        function openLuBo(){
            var mData={
               indexName:'index_frm',
               fixed:true,
               videowidth:720,
               videoheight:1280,
               videofps:25,
               fixed:true,
               uri:'http://talk.cocophp.com/index/file.html',
               imageUri:'http://talk.cocophp.com/index/file.html',
               cameraorientation:90,
               outorientation:0,
               }

         mVideoTape.openNativeVideo(mData)
        }

         function openRemoveLuBo(){

            mVideoTape.removeNativeVideo()

         }
         function openChioceVido(){

             var mData={
              uri:'http://talk.cocophp.com/index/file.html',
              imageUri:'http://talk.cocophp.com/index/file.html',
               indexName:'index_frm'
             }

            mVideoTape.chioceVideo(mData)
         }

        function openNaXiangVido(){
 				var mData = {
                    lift:0,
                    top:0,
                    hight:200,
                    width:-1,
                    fullScreen:false,
                    fixed:true,
                    indexName:'index_frm',
                    maxprobetime:2000,
                    moveImageheight:150,
                    moveImagewidth:190,
                    listImagewidth:800,
                    listImageheight:400,
                    uri:'http://resource.apicloud.com/video/apicloud3.mp4',
                    imageuri:'http://p3.pstatp.com/large/pgc-image/1531295191440e373715944',
                    listvoiduri:["http://jzvd.nathen.cn/c494b340ff704015bb6682ffde3cd302/64929c369124497593205a4190d7d128-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/63f3f73712544394be981d9e4f56b612/69c5767bb9e54156b5b60a1b6edeb3b5-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/b201be3093814908bf987320361c5a73/2f6d913ea25941ffa78cc53a59025383-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/d2438fd1c37c4618a704513ad38d68c5/68626a9d53ca421c896ac8010f172b68-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/25a8d119cfa94b49a7a4117257d8ebd7/f733e65a22394abeab963908f3c336db-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/7512edd1ad834d40bb5b978402274b1a/9691c7f2d7b74b5e811965350a0e5772-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/c6e3dc12a1154626b3476d9bf3bd7266/6b56c5f0dc31428083757a45764763b0-5287d2089db37e62345123a1be272f8b.mp4"],
                    listimageuri:["http://jzvd-pic.nathen.cn/jzvd-pic/00b026e7-b830-4994-bc87-38f4033806a6.jpg",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/1d935cc5-a1e7-4779-bdfa-20fd7a60724c.jpg",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/a019ffc1-556c-4a85-b70c-b1b49811d577.jpg",
                    "http://wx2.sinaimg.cn/mw690/006ZrXHXgy1fsr074hxtyg308w07xu0x.gif",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/f03cee95-9b78-4dd5-986f-d162c06c385c.png",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/e7ea659f-c3d2-4979-9ea5-f993b05e5930.png",
                    ""]
		         }
			mVideoTape.openVido(mData)
		}
		function openNaXiangFllu(){
		        var mData = {
                    lift:0,
                    top:0,
                    hight:-1,
                    width:-1,
                    fullScreen:false,
                    fixed:true,
                    indexName:'index_frm',
                    maxprobetime:2000,
                    moveImageheight:150,
                    moveImagewidth:190,
                    listImagewidth:800,
                    listImageheight:400,
                    uri:'http://resource.apicloud.com/video/apicloud3.mp4',
                    imageuri:'http://p3.pstatp.com/large/pgc-image/1531295191440e373715944',
                     listvoiduri:["http://jzvd.nathen.cn/c494b340ff704015bb6682ffde3cd302/64929c369124497593205a4190d7d128-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/63f3f73712544394be981d9e4f56b612/69c5767bb9e54156b5b60a1b6edeb3b5-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/b201be3093814908bf987320361c5a73/2f6d913ea25941ffa78cc53a59025383-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/d2438fd1c37c4618a704513ad38d68c5/68626a9d53ca421c896ac8010f172b68-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/25a8d119cfa94b49a7a4117257d8ebd7/f733e65a22394abeab963908f3c336db-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/7512edd1ad834d40bb5b978402274b1a/9691c7f2d7b74b5e811965350a0e5772-5287d2089db37e62345123a1be272f8b.mp4",
                    "http://jzvd.nathen.cn/c6e3dc12a1154626b3476d9bf3bd7266/6b56c5f0dc31428083757a45764763b0-5287d2089db37e62345123a1be272f8b.mp4"],
                    listimageuri:["http://jzvd-pic.nathen.cn/jzvd-pic/00b026e7-b830-4994-bc87-38f4033806a6.jpg",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/1d935cc5-a1e7-4779-bdfa-20fd7a60724c.jpg",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/a019ffc1-556c-4a85-b70c-b1b49811d577.jpg",
                    "http://wx2.sinaimg.cn/mw690/006ZrXHXgy1fsr074hxtyg308w07xu0x.gif",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/f03cee95-9b78-4dd5-986f-d162c06c385c.png",
                    "http://jzvd-pic.nathen.cn/jzvd-pic/e7ea659f-c3d2-4979-9ea5-f993b05e5930.png",
                    ""]
		        }

				mVideoTape.openFullVido(mData)
		}
		function openStop(){
				mVideoTape.openPause()
		}
		function openBigin(){
				mVideoTape.openSatrt()
		}
		function openOver(){
				mVideoTape.openStop()

		}
		function openNew(){

				var mData = {
                    uri:'rtmp://live.hkstv.hk.lxdns.com/live/hks',
                    isPlay:true
		        }

				mVideoTape.openNextPlay(mData)

		}
		function openVolume(){

				var mData = {

                    volume:0.0
		        }

				mVideoTape.openVolumeSetting(mData)

		}

		function openViewLooper(){

				var mData = {
                    looper:false
		        }
				mVideoTape.openLooper(mData)

		}
		function openViewSkip(){

				var mData = {
                    position:1000,
                    speed:0.1,
                    maxsizeinbytes:1024,
		        }
				mVideoTape.openSkipPostion(mData)

		}
		function openHitView(){
				mVideoTape.removeVido()

		}

		function openProgreBar(){

				var mData = {
                    isShown:false,
		        }
				mVideoTape.showProgress(mData)

		}

		function openPermision(){
		    mVideoTape.shudlePermission()
		}
        function  permisionCheck(){
             mVideoTape.checkPermision();
        }
    </script>
</head>
<body>
<div id="wrap">
    <div id="main">
        <br>
        <div class="clickbtn" tapmode="active" onclick="permisionCheck()">
            <button>验证权限</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openPermision()">
            <button>必须要获取的权限</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openZhiBo()">
            <button>打开直播</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openRemoveZhiBo()">
            <button>移除直播</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openLuBo()">
            <button>打开录播</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openRemoveLuBo()">
            <button>移除录播</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openChioceVido()">
            <button>上传本地视频</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openNaXiangVido()">
            <button>打开视频播放器</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openNaXiangFllu()">
            <button>全屏开始播放</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openStop()">
            <button>暂停</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openBigin()">
            <button>开始</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openOver()">
            <button>结束</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openNew()">
            <button>下一个(再播放一个)</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openVolume()">
            <button>静音</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openViewLooper()">
            <button>设置是否循环</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openViewSkip()">
            <button>设置播放进度</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openHitView()">
            <button>隐藏或者删除播放器</button>
        </div>
        <br>
        <div class="clickbtn" tapmode="active" onclick="openProgreBar()">
            <button>显示或隐藏进度条</button>
        </div>

    </div>
</div>
</body>
</html>